The invention relates generally to apparatus for compressing data for storage or transmission, and more particularly to a method and apparatus for compressing input signal data for storage in a waveform recorder based on the bandwidth of the signal.
Data compression can be used to reduce the data storage capacity or the transmission bandwidth requirements of an instrument or data communications system. Taking advantage of the redundancies in the original input signal, only the data points needed to represent the nonredundant information of the signal are stored or transmitted, and intermediate data points are eliminated.
In digital systems for storing a representation of analog signals, the sampling rate should be above the Nyquist frequency of the input signal. The higher the bandwidth of the input signal, the higher the sampling rate must be. Similarly, for signals with a low bandwidth, the sampling rate can be lower. For various reasons, it is impractical to change the initial rate at which the input signal is sampled. It is easier to sample at a uniform high rate, then resample before storing or transmitting the sampled signal. In the resampling step, the redundant data points of low bandwidth signals can be eliminated. The original signal can be reconstructed from the stored data points and information defining the sampling rate.
Data compression is particularly advantageous in waveform recorders and analyzers. These instruments store data from an event or a signal transient. In order to capture the most detailed information possible, the sampling is done at a very high rate, and stored in a very fast memory. To achieve the high speed required at an economic cost, the memory must be relatively small. Using data compression techniques, the apparent size of the memory can be increased, and data can be stored for a longer event or transient without compromising the frequency of the sampling rate used for intervals with high information content.
Early data compression devices used analog techniques, based on the amplitude or the slope of the input signal. The amplitude based devices compared the amplitude of the input signal to a threshold. The signal was sampled and data stored when the input signal amplitude exceeded the threshold, and no data was stored when the amplitude was below the threshold. Similarly, the slope based devices compared the rate of change of the input signal amplitude to a threshold, and sampled and stored data only when the slope exceeded the threshold.
The simple analysis performed by the amplitude and the slope techniques limited the amount of data compression that could be achieved for a given input signal, and thereby limited the amount of useful information that could be stored in a limited size memory.
Another approach used a digital technique, with digital filters to analyze the frequency content of an input signal. The sampling rate was adjusted as a function of the highest frequency component of the input signal. This approach allowed a more sophisticated analysis of the input signal, and provided for multiple sampling rates. However, it has several disadvantages. In particular, high frequency noise in the input signal can cause the sampling rate to remain high even when the actual bandwidth and information content is low.
One object of the invention is to provide a method and apparatus for making a more accurate analysis of the information content of an input signal and accordingly performing enhanced data compression.
Another object of the invention is to provide a method and apparatus for selecting an appropriate sampling rate for an input signal based on a dynamic measurement of the bandwidth of the signal.
To achieve these and other objects, in accordance with the teachings of the invention, an appropriate sampling rate is selected by applying a short time Fourier transform to the input signal to measure the bandwidth of the input signal and changing the sampling rate as a function of the bandwidth. In the preferred embodiment, the bandwidth of the input signal is determined by comparing the power of the entire input signal with the power of the input signal within a selected bandwidth. A discrete fourier transform is used to perform the bandwidth analysis.